import request from '@/utils/request'

// 查询工资项
export function querySalaryBasedataInfo(query) {
  return request({
    url: '/salaryDasedataController/querySalaryBasedataInfo',
    method: 'get',
    params: query
  })
}
// 查询人员类型
export function queryPersonType(query) {
  return request({
    url: '/PersonTypeSalaryController/getAllPersonType',
    method: 'get',
    params: query
  })
}
// 根据人员类型获得工资项
export function queryPersonTypeSalaryByType(query) {
  return request({
    url: '/PersonTypeSalaryController/queryPersonTypeSalaryByType',
    method: 'get',
    params: query
  })
}

// 保存工资项和单位
export function saveAgencySalary(data) {
  return request({
    url: '/PersonTypeSalaryController/savePersonTypeSalary',
    method: 'post',
    data
  })
}

// 根据单位id查询该单位下已挂接的工资项
export function queryAgencySalaryInfoByAgencyId(query) {
  return request({
    url: '/agencySalaryController/queryAgencySalaryInfo',
    method: 'get',
    params: query
  })
}
//单位工资采集保存
export function inseStsalaryBasedata(data) {
  return request({
    url: '/payroIitemController/inseStsalaryBasedata',
    method: 'post',
    data
  })
}
//查询接口
export function selSalaryBasedata(query) {

  return request({
    url: '/payroIitemController/selSalaryBasedata',
    method: 'get',
    params: query
  })
}
//查询接口
export function CopySalaryItem(data) {
  return request({
    url: '/payroIitemController/CopySalaryItem',
    method: 'post',
    data: data
  })
}